extends Resource

class_name SettingData

# 一一对应我们设置页面里面的每一项 进行存储
@export_subgroup('基础设置')
@export var sidebarShrinked:bool = true :
	get:
		return sidebarShrinked
	set(data):
		if data != sidebarShrinked:
			sidebarShrinked = data
			emit_changed()
	
@export var currentTheme:String = '白色' :
	get:
		return currentTheme
	set(new_data):
		if new_data!=currentTheme:
			currentTheme = new_data
			emit_changed()
		
@export var autoSave:bool = false :
	get:
		return autoSave
	set(data):
		if data != autoSave:
			autoSave = data
			emit_changed()
			
@export var doCopyToWorkspace:bool = false :
	get:
		return doCopyToWorkspace
	set(data):
		if data != doCopyToWorkspace:
			doCopyToWorkspace = data
			emit_changed()

@export var doScheduleFromToday:bool = false:
	get:
		return doScheduleFromToday
	set(val):
		if val != doScheduleFromToday:
			doScheduleFromToday = val
			emit_changed()

@export var autoUpdateWorkingHoursBySubtasks:bool = false:
	get:
		return autoUpdateWorkingHoursBySubtasks
	set(val):
		if val != autoUpdateWorkingHoursBySubtasks:
			autoUpdateWorkingHoursBySubtasks = val
			emit_changed()

@export var eliminateEpochNumWhenNoEnoughSpace:bool = true:
	get:
		return eliminateEpochNumWhenNoEnoughSpace
	set(val):
		if val != eliminateEpochNumWhenNoEnoughSpace:
			eliminateEpochNumWhenNoEnoughSpace = val
			emit_changed()

@export var hideDelayedIterms:bool = true:
	get:
		return hideDelayedIterms
	set(val):
		if val != hideDelayedIterms:
			hideDelayedIterms = val
			emit_changed()

@export_subgroup('Webdav')
@export var webdavServerURL:String :
	get:
		return webdavServerURL
	set(val):
		if val != webdavServerURL:
			webdavServerURL = val
			emit_changed()

@export var webdavUsernamme:String :
	get:
		return webdavUsernamme
	set(val):
		if val != webdavUsernamme:
			webdavUsernamme = val
			emit_changed()

@export var webdavPassword:String :
	get:
		return webdavPassword
	set(val):
		if val != webdavPassword:
			webdavPassword = val
			emit_changed()

@export var webdavValidated:bool = false :
	get:
		return webdavValidated
	set(val):
		if val != webdavValidated:
			webdavValidated = val
			emit_changed()

@export var webdavRemoteFolderPath:String = '' :
	get:
		return webdavRemoteFolderPath
	set(val):
		if val != webdavRemoteFolderPath:
			webdavRemoteFolderPath = val
			emit_changed()

@export_subgroup('Style')
@export var useWideScrollbar:bool = false :
	get:
		return useWideScrollbar
	set(val):
		if val != useWideScrollbar:
			useWideScrollbar = val
			emit_changed()

@export_subgroup('Display')
@export var resolution:String = '1600*2000' :
	get:
		return resolution
	set(val):
		if val != resolution:
			resolution = val
			emit_changed()
